package com.example.landlord.demo.utils.system;

import org.java_websocket.WebSocket;

//用户类
public class User {
    String name;
    String id;  //用户的账号,应该为唯一值
    GameType gameType=GameType.NOGAME;  //用户当前参加的游戏
    Game game;
    String picture;        //头像
    WebSocket webSocket;    //用户当前进行的连接

    private UserStatus status = UserStatus.NOTLINE; //默认不在线

    public UserStatus getStatus() {
        return status;
    }

    public void setStatus(UserStatus status) {
        this.status = status;
    }

    @Override
    public String toString() {
        return "User{" +
                "name='" + name + '\'' +
                ", id='" + id + '\'' +
                ", game=" + game +
                ", status=" + status +
                '}';
    }
}
